<%@page pageEncoding="UTF-8" %>
<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="sf" uri="http://www.springframework.org/tags/form" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/fmt" prefix="fmt" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<html>
<head>
    <meta charset="utf-8"/>
    <title>汇总表</title>
    <style>
        h5 {
            text-align: center;
        }

        table {
            border-collapse: collapse;
            margin: 0 auto;
        }

        th, td {
            width: 28px;
            font-family: "微软雅黑";
            font-size: 16px;
            vertical-align: top;
            text-align: center;
        }

        th {
            line-height: 25px;
        }

    </style>
    <script>
        window.onload = function () {
            function immediately() {
                var href = location.href;
                var str = "grade=";
                var arr = href.split("=");
                if (str.indexOf(href) != -1) {

                }
                var grade = arr[1].substring(4, 0)
                for (var i = 0; i < document.getElementById("grd").children.length; i++) {

                    var op = document.getElementById("grd").children[i].value;
                    if (op == grade) {
                        document.getElementById("grd").value = op
                    }


                }
            }

            immediately();
        }
    </script>
    <script>
        function getData() {
//            document.getElementById("name").value=this.children[0].innerHTML;
            document.getElementById("course").value = this.children[1].innerHTML;
            document.getElementById('course_form').submit();
        }
    </script>
</head>
<body>
<c:if test="${param.grade != null}">
    <c:forEach items="${pagers.datas}" var="total" begin="0" end="0">
        <h4>四川旅游学院本科（${total.major}专业）专业课程质量（学生/二级督导/专家组）评价统计表</h4>
    </c:forEach>
</c:if>
<c:if test="${param.grade == null}">
    <table style="width: 608px">
        <tr style="width: 607px">
            <td colspan="19">
                <form method="get" action="<%=request.getContextPath()%>/total/total_info">
                        <%--<h4>请选择查询起始年级</h4>--%>
                    <select name="grade" id="grd">
                        <option value="请选择查询起始年级">请选择查询起始年级</option>
                        <option name="grade" value="2012">2012</option>
                        <option name="grade" value="2013">2013</option>
                        <option name="grade" value="2014">2014</option>
                        <option name="grade" value="2015">2015</option>
                        <option name="grade" value="2016">2016</option>
                        <option name="grade" value="2017">2017</option>
                        <option name="grade" value="2018">2018</option>
                        <option name="grade" value="2019">2019</option>
                        <option name="grade" value="2020">2020</option>
                    </select>

                    <select id="department" name="department">
                        <option name="department" value="${department}">
                            <c:if test="${param.department eq null}">请选择院系</c:if>
                                ${param.department}
                        </option>
                    </select>
                    <select id="major" name="major">
                        <option name="major" value="${major}">
                            <c:if test="${param.major eq null}">请选择专业</c:if>
                                ${param.major}</option>
                    </select>
                    <input type="submit" value="查询"/>
                </form>
            </td>
        </tr>
    </table>
</c:if>
<c:if test="${param.grade != null}">
    <table border="1">
        <tr>
            <td colspan="16">
                <form method="get" action="<%=request.getContextPath()%>/total/total_info">

                    <select name="grade" id="grd">
                        <option value="请选择查询起始年级">请选择查询起始年级</option>
                        <option name="grade" value="2012">2012</option>
                        <option name="grade" value="2013">2013</option>
                        <option name="grade" value="2014">2014</option>
                        <option name="grade" value="2015">2015</option>
                        <option name="grade" value="2016">2016</option>
                        <option name="grade" value="2017">2017</option>
                        <option name="grade" value="2018">2018</option>
                        <option name="grade" value="2019">2019</option>
                        <option name="grade" value="2020">2020</option>
                    </select>

                    <select id="department" name="department">
                        <option name="department" value="${department}">
                            <c:if test="${param.department eq null}">请选择院系</c:if>
                                ${param.department}
                        </option>
                    </select>
                    <select id="major" name="major">
                        <option name="major" value="${major}">
                            <c:if test="${param.major eq null}">请选择专业</c:if>
                                ${param.major}</option>
                    </select>
                    <input type="submit" value="查询"/>
                </form>
            </td>

            <td colspan="3">
                <form action="<%=request.getContextPath()%>/total/out_info">
                    <input type="hidden" name="grade" value="${param.grade}">
                    <input type="hidden" name="department" value="${param.department}">
                    <input type="hidden" name="major" value="${param.major}">
                    <input type="submit" value="点击导出"/>
                </form>
            </td>

        </tr>
        <tr>
            <th rowspan="2" style="text-align: center;line-height: 20px;vertical-align: middle">序号</th>
            <th rowspan="2" style="text-align: center;vertical-align: middle">课程名称</th>
            <c:if test="${param.grade == null}">
                <th colspan="4">2013级本科班</th>
                <th colspan="4">2014级本科班</th>
                <th colspan="4">2015级本科班</th>
                <th colspan="4">2016级本科班</th>
            </c:if>
            <c:if test="${param.grade != null}">
                <th colspan="4">${param.grade}级本科班</th>
                <th colspan="4">${param.grade + 1}级本科班</th>
                <th colspan="4">${param.grade + 2}级本科班</th>
                <th colspan="4">${param.grade + 3}级本科班</th>
            </c:if>
            <th rowspan="2" style="text-align: center;vertical-align: middle;width:70px;">总评得分</th>
        </tr>
        <tr>
            <th style="text-align: center;vertical-align: middle;">学生评价</th>
            <th style="text-align: center;vertical-align: middle;">二级督导</th>
            <th style="text-align: center;vertical-align: middle;">校专家组</th>
            <th style="text-align: center;vertical-align: middle;">平均分数</th>
            <th style="text-align: center;vertical-align: middle;">学生评价</th>
            <th style="text-align: center;vertical-align: middle;">二级督导</th>
            <th style="text-align: center;vertical-align: middle;">校专家组</th>
            <th style="text-align: center;vertical-align: middle;">平均分数</th>
            <th style="text-align: center;vertical-align: middle;">学生评价</th>
            <th style="text-align: center;vertical-align: middle;">二级督导</th>
            <th style="text-align: center;vertical-align: middle;">校专家组</th>
            <th style="text-align: center;vertical-align: middle;">平均分数</th>
            <th style="text-align: center;vertical-align: middle;">学生评价</th>
            <th style="text-align: center;vertical-align: middle;">二级督导</th>
            <th style="text-align: center;vertical-align: middle;">校专家组</th>
            <th style="text-align: center;vertical-align: middle;">平均分数</th>
        </tr>

        <c:if test="${pagers.totalPage le 0 }">
            <tr>
                <td colspan="19">无相关评教信息</td>
            </tr>
        </c:if>
        <c:if test="${pagers.totalPage gt 0}">

            <c:forEach items="${pagers.datas}" var="total" varStatus="count">

                <tr class="tr">
                    <td>${count.index+1}</td>
                    <td style="color: #003366;width: 120px;">${total.course}</td>

                    <c:set var="tscore1"/>
                    <c:set var="tscore2"/>
                    <c:set var="tscore3"/>
                    <c:set var="tscore4"/>

                    <c:forEach items="${total.grades}" var="tgrade" varStatus="count">
                        <c:if test="${tgrade.grade eq param.grade}">
                            <c:if test="${ empty tgrade.scores}">
                                <td></td>
                                <td></td>
                                <td></td>
                                <td></td>
                                <c:set var="tcore1" value="${null}"/>
                            </c:if>
                            <c:if test="${ not empty tgrade.scores}">
                                <c:forEach items="${tgrade.scores}" var="score">
                                    <td><fmt:formatNumber type="number" value="${score.sScore}" pattern="0.00"
                                                                         maxFractionDigits="2"/></td>
                                    <td><fmt:formatNumber type="number" value="${score.cScore}" pattern="0.00"
                                                          maxFractionDigits="2"/></td>
                                    <td><fmt:formatNumber type="number" value="${score.eScore}" pattern="0.00"
                                                                         maxFractionDigits="2"/></td>
                                    <c:if test="${score.sScore != null && score.cScore != null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.cScore + score.eScore*1.3)/3}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore1"
                                               value="${(score.sScore*0.7 + score.cScore + score.eScore*1.3)/3}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore != null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.cScore + score.eScore*1.3)/2.3}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore1" value="${(score.cScore + score.eScore*1.3)/2.3}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore == null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.eScore*1.3)/2}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore1" value="${(score.sScore*0.7 + score.eScore*1.3)/2}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore != null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.cScore)/1.7}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore1" value="${(score.sScore*0.7 + score.cScore)/1.7}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore == null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number" value="${score.eScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore1" value="${score.eScore}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore != null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number" value="${score.cScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore1" value="${score.cScore}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore == null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number" value="${score.sScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore1" value="${score.sScore}"/>
                                    </c:if>
                                </c:forEach>
                            </c:if>
                        </c:if>
                        <c:if test="${tgrade.grade eq param.grade + 1}">
                            <c:if test="${ empty tgrade.scores}">
                                <td></td>
                                <td></td>
                                <td></td>
                                <td></td>
                                <c:set var="tcore2" value="${null}"/>
                            </c:if>
                            <c:if test="${ not empty tgrade.scores}">
                                <c:forEach items="${tgrade.scores}" var="score">
                                    <td><fmt:formatNumber type="number" value="${score.sScore}" pattern="0.00"
                                                          maxFractionDigits="2"/></td>
                                    <td><fmt:formatNumber type="number" value="${score.cScore}" pattern="0.00"
                                                                         maxFractionDigits="2"/></td>
                                    <td><fmt:formatNumber type="number" value="${score.eScore}" pattern="0.00"
                                                          maxFractionDigits="2"/></td>
                                    <c:if test="${score.sScore != null && score.cScore != null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.cScore + score.eScore*1.3)/3}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore2"
                                               value="${(score.sScore*0.7 + score.cScore + score.eScore*1.3)/3}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore != null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.cScore + score.eScore*1.3)/2.3}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore2" value="${(score.cScore + score.eScore*1.3)/2.3}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore == null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.eScore*1.3)/2}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore2" value="${(score.sScore*0.7 + score.eScore*1.3)/2}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore != null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.cScore)/1.7}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore2" value="${(score.sScore*0.7 + score.cScore)/1.7}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore == null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number" value="${score.eScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore2" value="${score.eScore}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore != null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number" value="${score.cScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore2" value="${score.cScore}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore == null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number" value="${score.sScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore2" value="${score.sScore}"/>
                                    </c:if>
                                </c:forEach>
                            </c:if>
                        </c:if>
                        <c:if test="${tgrade.grade eq param.grade + 2}">
                            <c:if test="${ empty tgrade.scores}">
                                <td></td>
                                <td></td>
                                <td></td>
                                <td></td>
                                <c:set var="tcore3" value="${null}"/>
                            </c:if>
                            <c:if test="${ not empty tgrade.scores}">
                                <c:forEach items="${tgrade.scores}" var="score">
                                    <td><fmt:formatNumber type="number" value="${score.sScore}" pattern="0.00"
                                                          maxFractionDigits="2"/></td>
                                    <td><fmt:formatNumber type="number" value="${score.cScore}" pattern="0.00"
                                                          maxFractionDigits="2"/></td>
                                    <td><fmt:formatNumber type="number" value="${score.eScore}" pattern="0.00"
                                                          maxFractionDigits="2"/></td>
                                    <c:if test="${score.sScore != null && score.cScore != null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.cScore + score.eScore*1.3)/3}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore3"
                                               value="${(score.sScore*0.7 + score.cScore + score.eScore*1.3)/3}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore != null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.cScore + score.eScore*1.3)/2.3}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore3" value="${(score.cScore + score.eScore*1.3)/2.3}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore == null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.eScore*1.3)/2}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore3" value="${(score.sScore*0.7 + score.eScore*1.3)/2}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore != null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.cScore)/1.7}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore3" value="${(score.sScore*0.7 + score.cScore)/1.7}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore == null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number" value="${score.eScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore3" value="${score.eScore}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore != null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number" value="${score.cScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore3" value="${score.cScore}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore == null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number" value="${score.sScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore3" value="${score.sScore}"/>
                                    </c:if>
                                </c:forEach>
                            </c:if>
                        </c:if>
                        <c:if test="${tgrade.grade eq param.grade +3}">
                            <c:if test="${ empty tgrade.scores}">
                                <td></td>
                                <td></td>
                                <td></td>
                                <td></td>
                                <c:set var="tcore4" value="${null}"/>
                            </c:if>
                            <c:if test="${ not empty tgrade.scores}">
                                <c:forEach items="${tgrade.scores}" var="score">
                                    <td><fmt:formatNumber type="number" value="${score.sScore}" pattern="0.00"
                                                          maxFractionDigits="2"/></td>
                                    <td><fmt:formatNumber type="number" value="${score.cScore}" pattern="0.00"
                                                                         maxFractionDigits="2"/></td>
                                    <td><fmt:formatNumber type="number" value="${score.eScore}" pattern="0.00"
                                                          maxFractionDigits="2"/></td>
                                    <c:if test="${score.sScore != null && score.cScore != null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.cScore + score.eScore*1.3)/3}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore4"
                                               value="${(score.sScore*0.7 + score.cScore + score.eScore*1.3)/3}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore != null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.cScore + score.eScore*1.3)/2.3}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore4" value="${(score.cScore + score.eScore*1.3)/2.3}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore == null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.eScore*1.3)/2}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore4" value="${(score.sScore*0.7 + score.eScore*1.3)/2}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore != null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number"
                                                              value="${(score.sScore*0.7 + score.cScore)/1.7}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore4" value="${(score.sScore*0.7 + score.cScore)/1.7}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore == null && score.eScore != null}">
                                        <td><fmt:formatNumber type="number" value="${score.eScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore4" value="${score.eScore}"/>
                                    </c:if>
                                    <c:if test="${score.sScore == null && score.cScore != null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number" value="${score.cScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore4" value="${score.cScore}"/>
                                    </c:if>
                                    <c:if test="${score.sScore != null && score.cScore == null && score.eScore == null}">
                                        <td><fmt:formatNumber type="number" value="${score.sScore}"
                                                              maxFractionDigits="1"/></td>
                                        <c:set var="tcore4" value="${score.sScore}"/>
                                    </c:if>
                                </c:forEach>
                            </c:if>
                        </c:if>
                    </c:forEach>
                    <c:if test="${tcore1 != null && tcore2 != null && tcore3 != null && tcore4 != null}">
                        <td><fmt:formatNumber type="number" value="${(tcore1 + tcore2 + tcore3 + tcore4)/4}"
                                              maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 != null && tcore2 != null && tcore3 != null && tcore4 == null}">
                        <td><fmt:formatNumber type="number" value="${(tcore1 + tcore2 + tcore3)/3}"
                                              maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 != null && tcore2 != null && tcore3 == null && tcore4 != null}">
                        <td><fmt:formatNumber type="number" value="${(tcore1 + tcore2 + tcore4)/3}"
                                              maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 != null && tcore2 == null && tcore3 != null && tcore4 != null}">
                        <td><fmt:formatNumber type="number" value="${(tcore1 + tcore3 + tcore4)/3}"
                                              maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 != null && tcore2 != null && tcore3 == null && tcore4 == null}">
                        <td><fmt:formatNumber type="number" value="${(tcore1 + tcore2)/2}" maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 != null && tcore2 == null && tcore3 != null && tcore4 == null}">
                        <td><fmt:formatNumber type="number" value="${(tcore1 + tcore3)/2}" maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 != null && tcore2 == null && tcore3 == null && tcore4 != null}">
                        <td><fmt:formatNumber type="number" value="${(tcore1 + tcore4)/2}" maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 != null && tcore2 == null && tcore3 == null && tcore4 == null}">
                        <td><fmt:formatNumber type="number" value="${tcore1}" maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 == null && tcore2 != null && tcore3 != null && tcore4 != null}">
                        <td><fmt:formatNumber type="number" value="${(tcore2 + tcore3 + tcore4)/3}"
                                              maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 == null && tcore2 != null && tcore3 != null && tcore4 == null}">
                        <td><fmt:formatNumber type="number" value="${(tcore2 + tcore3)/2}" maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 == null && tcore2 != null && tcore3 == null && tcore4 != null}">
                        <td><fmt:formatNumber type="number" value="${(tcore2 + tcore4)/2}" maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 == null && tcore2 != null && tcore3 == null && tcore4 == null}">
                        <td><fmt:formatNumber type="number" value="${tcore2}" maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 == null && tcore2 == null && tcore3 != null && tcore4 != null}">
                        <td><fmt:formatNumber type="number" value="${(tcore3 + tcore4)/2}" maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 == null && tcore2 == null && tcore3 != null && tcore4 == null}">
                        <td><fmt:formatNumber type="number" value="${tcore3}" maxFractionDigits="1"/></td>
                    </c:if>
                    <c:if test="${tcore1 == null && tcore2 == null && tcore3 == null && tcore4 != null}">
                        <td><fmt:formatNumber type="number" value="${tcore4}" maxFractionDigits="1"/></td>
                    </c:if>
                </tr>
            </c:forEach>
            <tr>
                <td colspan="19">
                    <jsp:include page="/jsp/pager.jsp">
                        <jsp:param value="/total/total_info" name="url"/>
                        <jsp:param value="${pagers.totalPage }" name="items"/>
                        <jsp:param value="grade,department,major" name="params"/>
                    </jsp:include>
                </td>
            </tr>
        </c:if>
    </table>
</c:if>
<form action="<%=request.getContextPath()%>/course/totalCourseInfo" id="course_form" method="get">
    <input type="hidden" name="grade" value="${param.grade}">
    <input type="hidden" name="department" value="${param.department}">
    <input type="hidden" name="major" value="${param.major}">
    <input type="hidden" id="course" name="course"/>
</form>
<script type="text/javascript">
    var tds = document.getElementsByClassName("tr");
    var obj = null;
    for (var i = 0, len = tds.length; i < len; i++) {
        obj = tds[i];
        obj.onclick = getData;  //这里没有括号
    }
</script>

</body>
</html>
<%--<script src="/resources/js/total.js"></script>--%>